Particular embodiments generally relate to database systems.
Online analytical processing (OLAP) applications are used to provide answers to analytical queries that are multidimensional in nature. Complex analytical and ad hoc queries may be provided by users. Because multidimensional data may organize data in more than two dimensions, a multidimensional data model is used to store the data in a database. A cube has been developed as a model to store multidimensional objects where the cube is stored as multiple blocks of data. The blocks are stored in fully-exploded arrays for different two-dimensional combinations of the multidimensional data. With a large number of dimensions, not all combinations may include data. For example, if a first dimension is a certain product and a second dimension is geographical areas. The sales of a product in different geographical areas over a time period may be requested, but the company may not sell products in all geographical areas. Blocks for these geographical areas will not contain data and are considered sparse. However, for the areas in which a company has a large amount of sales, the blocks include a lot of data and are considered dense. Because the database reserves a fully-exploded array for each combination that is possible, this results in a lot of unused database memory.